#pragma once
#include <Windows.h>
#include <vector>
#include "CyMessageFilter.h"

// This class is base for CyGUITest, CyGUIButton, CyGUIEditBox, CyGUIPicture
// act like an interface, for handling message sending to that warper

class CyMessageProcessor
{
public:
	// Invoke every message filter in message filter list.
	static BOOL ProcessMessage(HWND hWnd,
		UINT message, WPARAM wParam, LPARAM lParam);

	static void AddFilter(CyMessageFilter *filter);

	static void RemoveFilter(CyMessageFilter *filter);

private:

	typedef std::vector<CyMessageFilter*> FilterList;

	// prevent creating object from this static class
	CyMessageProcessor() {};

	// List of message filters
	static FilterList _filterList;
};